import {
  NAutoComplete,
  NCascader,
  NColorPicker,
  NDatePicker,
  NDynamicInput,
  NDynamicTags,
  NInput,
  NInputNumber,
  NMention,
  NRate,
  NSelect,
  NSlider,
  NTimePicker,
  NTreeSelect,
  NUpload,
} from 'naive-ui'
import StnListInput from '../../StnListInput'
import StnRadioBtnGroup from '../../StnRadioBtnGroup'
import StnSwitch from '../../StnSwitch'
import {IptTypeEnum} from '../enums/ipt-type-enum.ts'

/**
 * 输入组件类型与输入组件的映射常量对象
 */
export const IptTypeMapConst: Record<IptTypeEnum, any> = {
  [IptTypeEnum.AUTO_COMPLETE]: NAutoComplete,
  [IptTypeEnum.CASCADER]: NCascader,
  [IptTypeEnum.COLOR_PICKER]: NColorPicker,
  [IptTypeEnum.DATA_PICKER]: NDatePicker,
  [IptTypeEnum.DYNAMIC_INPUT]: NDynamicInput,
  [IptTypeEnum.DYNAMIC_TAGS]: NDynamicTags,
  [IptTypeEnum.INPUT]: NInput,
  [IptTypeEnum.INPUT_NUMBER]: NInputNumber,
  [IptTypeEnum.MENTION]: NMention,
  [IptTypeEnum.RADIO_BTN_GROUP]: StnRadioBtnGroup,
  [IptTypeEnum.RATE]: NRate,
  [IptTypeEnum.SELECT]: NSelect,
  [IptTypeEnum.SLIDER]: NSlider,
  [IptTypeEnum.SWITCH]: StnSwitch,
  [IptTypeEnum.TIME_PICKER]: NTimePicker,
  [IptTypeEnum.TREE_SELECT]: NTreeSelect,
  [IptTypeEnum.UPLOAD]: NUpload,
  [IptTypeEnum.LIST_INPUT]: StnListInput,
}
